public class Java19 {
    public static void main(String[] args) {
        int[] a = new int[10];//1
        int[] b = new int[]{0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10};//2
        int[] c = {0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10};//3
        for (int i = 0; i < b.length; i++) {
            System.out.println(b[i]);

        }
        int[] d = new int[]{1, 2, 3, 4, 5, 6, 7, 8, 9};
        //查找，查找下标为6的元素
        System.out.println(d[6]);
        //删除，删除下标为6的元素
        d[6] = 0;
        //修改，修改下标为1的元素，修改为99
        d[1] = 99;
        //数组遍历
        for (int i = 0; i < d.length; i++) {
            System.out.println(d[i]);
        }
        int min = 5, max = 5;
        int[] g = new int[]{1, 2, 3, 4, 5, 6, 7, 8, 9};
        for (int i = 0; i < g.length; i++) {
            if (g[i] < min) min = g[i];
            if (g[i] > max) max = g[i];
        }
        System.out.println("数组最小值是：" + min);
        System.out.println("数组最大值是：" + max);
    }
}
